Skip to content

Instantly share code, notes, and snippets.

@gmpsankalpa
gmpsankalpa / CompleteRecentDiscordQuest.md
Created May 8, 2024 18:45
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

@rms1000watt
rms1000watt / jinja2-omit-comma-from-item.txt.j2
Created October 18, 2019 21:10
Jinja2 omit comma from last item in list
# Courtesy of: https://stackoverflow.com/a/11974399
{%- for item in items %}
[
"{{item}}"{{ "," if not loop.last }}
]
{%- endfor %}
@vratiu
vratiu / .bash_aliases
Last active May 8, 2024 18:55
Git shell coloring
# Customize BASH PS1 prompt to show current GIT repository and branch.
# by Mike Stewart - http://MediaDoneRight.com
# SETUP CONSTANTS
# Bunch-o-predefined colors. Makes reading code easier than escape sequences.
# I don't remember where I found this. o_O
# Reset
Color_Off="\[\033[0m\]" # Text Reset
@dmnsgn
dmnsgn / WebGL-WebGPU-frameworks-libraries.md
Last active May 8, 2024 18:53
A collection of WebGL and WebGPU frameworks and libraries

A non-exhaustive list of WebGL and WebGPU frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are wip/outdated/not maintained anymore.

Engines and libraries ⚙️

Name Stars Last Commit Description
three.js ![GitHub
@m-tatsuto
m-tatsuto / Controller.swift
Created November 24, 2016 02:09
Changing tab bar font in Swift3
let appearance = UITabBarItem.appearance()
let attributes = [NSFontAttributeName: UIFont(name: "American Typewriter", size: 20),
NSForegroundColorAttributeName: UIColor.white]
appearance.setTitleTextAttributes(attributes, for: .normal)
@nadavrot
nadavrot / Matrix.md
Last active May 8, 2024 18:53
Efficient matrix multiplication

High-Performance Matrix Multiplication

This is a short post that explains how to write a high-performance matrix multiplication program on modern processors. In this tutorial I will use a single core of the Skylake-client CPU with AVX2, but the principles in this post also apply to other processors with different instruction sets (such as AVX512).

Intro

Matrix multiplication is a mathematical operation that defines the product of

@tzmartin
tzmartin / m3u8-to-mp4.md
Last active May 8, 2024 18:52
m3u8 stream to mp4 using ffmpeg

1. Copy m3u8 link

Alt text

2. Run command

echo "Enter m3u8 link:";read link;echo "Enter output filename:";read filename;ffmpeg -i "$link" -bsf:a aac_adtstoasc -vcodec copy -c copy -crf 50 $filename.mp4
# libraries
import os
import matplotlib.pyplot as plt
import pandas as pd
import textwrap
# load the data
df = pd.read_csv(os.path.join('..', 'data', 'quest.csv'))
# Some questions are rather long. To nicely display them in the figure they need to be wrapped.
@twolfson
twolfson / .gitconfig
Last active May 8, 2024 18:50
Proof of concept to explore merge conflict resolution with SOPS encoded files for https://github.com/mozilla/sops/issues/52
[mergetool "sops-mergetool"]
cmd = ./sops-mergetool.sh "$BASE" "$LOCAL" "$REMOTE" "$MERGED"